package com.duan.controller;

import com.duan.service.KaptchaService;
import com.duan.utils.ResponseResult;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.Map;


/**
 * @author db
 * @version 1.0
 * @description KaptchaController
 * @since 2024/10/7
 */
@RestController
public class KaptchaController {
    @Autowired
    private KaptchaService kaptchaService;

    @GetMapping("/getKaptchaImage")
    public ResponseResult getCode(){
        Map code = kaptchaService.getCode();
        return ResponseResult.okResult(code);
    }
}
